name 'Error' is not defined